<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>变量和常量</title>
</head>
<body>
    <script>
        // 1.变量
        let name = 'lbq'
        let age = 20
        age = 21
        console.log(name,age)
        // 2.常量
        const  PI = 3.1415926
        const user = {
            username: 'zhansan',
            password: '123456'
        }
        // 添加属性
        user.checkNum = 'aq12e'
        // 修改属性
        user.password = '112233'
        user.username = 'lisi'
        console.log(user)
        //增加元素
        const array = []
        //可以一次添加多个元素
        array.push(1,2,3,4,5,6)
        //删除元素
        array.shift()
        console.log(array)
    </script>
</body>
</html>